package code.jpanel.mainjpanel;

import code.init.MainStore;
import code.jpanel.LoginJPanel;
import code.jpanel.listener.ReturnMainMenuListener;

import java.awt.FlowLayout;
import java.awt.Graphics;

import javax.swing.ImageIcon;
import javax.swing.JPanel;

public class LoginMainJPanel extends JPanel {
	public LoginJPanel login;
	public static ImageIcon img;
	public LoginMainJPanel() {
		
		//setPreferredSize(new Dimension(1200,1000));
		setSize(1200,1000);
		setLayout(new FlowLayout());
		login=new LoginJPanel();
		add(login);//
		add(login.registJPanel);
		
	
		login.returnMenu.addActionListener(new ReturnMainMenuListener(this));
		setVisible(false);
	}
	public void paintComponent(Graphics g)
    {
		
		g.drawImage(img.getImage(),0,0, MainStore.win.getContentPane().getWidth(), MainStore.win.getContentPane().getHeight(),this);
    }
}
